<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
<title>Tipask's Control Panel</title>
<meta http-equiv="Content-Type" content="text/html; charset={APP_CHARSET}">
<link media="all" type="text/css" href="css/admin/admincp.css" rel="stylesheet"/>
<script type="text/javascript" src="js/jquery.js"></script>
<script src="js/admin.js"></script>
<script src="js/calendar.js"></script>
<script src="js/connSelectLocation.min.js"></script>
</head>

<body>

<div id="append">
</div>
<script type="text/javascript">
	function headermenu(ctrl) {
		ctrl.className = ctrl.className == 'otherson' ? 'othersoff' : 'otherson';
		var menu = document.getElementById('header_menu_body');
		if(!menu) {
			menu = document.createElement('div');
			menu.id = 'header_menu_body';
			menu.innerHTML = '<ul>' + document.getElementById('header_menu_menu').innerHTML + '</ul>';
			var obj = ctrl;
			var x = ctrl.offsetLeft;
			var y = ctrl.offsetTop;
			while((obj = obj.offsetParent) != null) {
				x += obj.offsetLeft;
				y += obj.offsetTop;
			}
			menu.style.left = x + 'px';
			menu.style.top = y + ctrl.offsetHeight + 'px';
			menu.className = 'togglemenu';
			menu.style.display = '';
			document.body.appendChild(menu);
		} else {
			menu.style.display = menu.style.display == 'none' ? '' : 'none';
		}
	}
</script>
<div class="container">
	<!--{if isset($message)}-->
		<!--{eval $type=isset($type)?$type:'correctmsg'; }-->
		<div class="{$type}"><p>{$message}</p></div>
	<!--{/if}-->
	<div class="mainbox nomargin">
		<form action="index.php?c=admin_user&a=edit&uid={$member['uid']}" method="post">
		
	  <table cellspacing="3" cellpadding="3" width="96%">
		<tr>
                <td class="tdLeft"><span style="color:red;">*</span>真实姓名：</td>
                <td class="tdRight">
                	<input maxlength="12" name="truename"  class="txt" type="text" value="{$member['truename']}" />
                	<span class="gray">限制在2-4个汉字字符，不能是英文，数字等。</span>
                </td>
              </tr>
			   <tr>
                <td class="tdLeft"><span style="color:red;">*</span>性&nbsp;&nbsp;&nbsp;别：</td>
                <td class="tdRight">
                	<input id="gender1" name="gender" type="radio"  {if 1==$member['gender'] }checked{/if}  value="1" /><label for="gender1">男</label>
                	<input id="gender2" name="gender" type="radio"  {if 0==$member['gender'] }checked{/if}  value="0" /><label for="gender2">女</label>
                </td>
              </tr>
              <tr>
                <td class="tdLeft"><span style="color:red;">*</span>生&nbsp;&nbsp;&nbsp;日：</td>
                <td class="tdRight">
                	<input class="txt" value="{$member['bday']}" id="bday" name="bday" readonly  onclick="showcalendar();" value="{$member['bday']}" />
                </td>
              </tr>
              
			   <tr>
                <td class="tdLeft"><span style="color:red;">*</span>手机号码：</td>
                <td class="tdRight"><input maxlength="12" name="mobile"   class="txt" type="text" value="{$member['mobile']}"/></td>
              </tr>
			   <tr>
                <td class="tdLeft"><span style="color:red;">*</span>Email：</td>
                <td class="tdRight">
                	<input maxlength="32" name="email" class="txt" type="text" value="{$member['email']}" />
                	<span class="gray">请输入常用邮箱，通过验证后可用于登录和找回密码。</span>
                </td>
              </tr>
              
              
		   <tr>
                <td class="tdLeft"><span style="color:red;">*</span>婚姻状况：</td>
                <td class="tdRight">
                	<input id="idtype1" name="marrytype" type="radio"   {if 1==$member['marrytype'] }checked{/if}   value="1"/><label for="idtype1">未婚</label>
                	<input id="idtype2" name="marrytype" type="radio"   {if 2==$member['marrytype'] }checked{/if}  value="2"/><label for="idtype2">已婚</label>
                	<input id="idtype3" name="marrytype" type="radio"   {if 3==$member['marrytype'] }checked{/if}  value="3"/><label for="idtype3">离异</label>
                	<input id="idtype3" name="marrytype" type="radio"   {if 4==$member['marrytype'] }checked{/if}  value="4"/><label for="idtype3">重组家庭</label>
                </td>
              </tr>

               <tr>
                <td class="tdLeft"><span style="color:red;">*</span>爱人姓名：</td>
                <td class="tdRight">
                	<input maxlength="12" name="lovertruename"  class="txt" type="text" value="{$member['lovertruename']}" />
                	<span class="gray">限制在2-4个汉字字符，不能是英文，数字等。</span>
                </td>
              </tr>
              <tr>
                <td class="tdLeft"><span style="color:red;">*</span>爱人生日：</td>
                <td class="tdRight">
                	<input class="txt" value="{$member['loverbday']}" id="loverbday" name="loverbday" readonly  onclick="showcalendar();" value="{$member['loverbday']}" />
                </td>
              </tr>
              
			   <tr>
                <td class="tdLeft"><span style="color:red;">*</span>爱人手机号码：</td>
                <td class="tdRight"><input maxlength="12" name="lovermobile"   class="txt" type="text" value="{$member['lovermobile']}"/></td>
              </tr>
			   <tr>
                <td class="tdLeft"><span style="color:red;">*</span>爱人Email：</td>
                <td class="tdRight">
                	<input maxlength="32" name="loveremail" class="txt" type="text" value="{$member['loveremail']}" />
                </td>
              </tr>
              

<!--{loop $member['childtruename'] $index $childtruename}-->	
             <tr>
                <td class="tdLeft"><span style="color:red;">*</span>孩子姓名：</td>
                <td class="tdRight">
                	<input maxlength="12" name="childtruename[]"  class="txt" type="text" value="{$member['childtruename'][$index]}" />
                	性别：<select  name="childgender[]">
			                	<option {if '1'==$member['childgender'][$index] }selected{/if} value="1">男</option>
			                	<option {if '2'==$member['childgender'][$index] }selected{/if} value="2">女</option>
		                	</select>
                	生日：<input class="txt"  name="childbday[]" readonly  onclick="showcalendar();"  value="{$member['childbday'][$index]}"  />
                </td>
              </tr>
<!--{/loop}-->
                 <tr id="morechild">
                	 <td>&nbsp;</td>
               	 <td ><input class="btn"  type="button" value="添加孩子..."   onclick="javascript:addchild();"  /></td>
              </tr>
              

		   <tr>
                <td class="tdLeft">固定电话：</td>
                <td class="tdRight"><input maxlength="12" name="phone"   class="txt" type="text" value="{$member['phone']}"/></td>
              </tr>
			   <tr>
                <td class="tdLeft">证件类型：</td>
                <td class="tdRight">
                	<input id="idtype1" name="idtype" type="radio"   {if 1==$member['idtype'] }checked{/if}   value="1"/><label for="idtype1">身份证</label>
                	<input id="idtype2" name="idtype" type="radio"   {if 2==$member['idtype'] }checked{/if}  value="2"/><label for="idtype2">护照</label>
                	<input id="idtype3" name="idtype" type="radio"   {if 3==$member['idtype'] }checked{/if}  value="3"/><label for="idtype3">驾驶证</label>
                </td>
              </tr>
			   <tr>
                <td class="tdLeft">证件号码：</td>
                <td class="tdRight">
                	<input maxlength="18" name="idno"  class="txt" type="text"  value="{$member['idno']}"/>
                </td>
              </tr>
			   <tr>
                <td colspan="2" height="18px"></td>
              </tr>
		<tr>
                <td class="tdLeft">现居住地：</td>
                <td class="tdRight"  id='conn-location-1' >
				<select id='conn-province'  name="province"><option value='0'>请选择</option></select>
				<select id='conn-city'  name="city"><option value='0'>请选择</option></select>
				<select id='conn-district'  name="district"><option value='0'>请选择</option></select>
				<br />
				<input type="text" id="address" name="address" class="txt350" maxlength="50" value="{$member['address']}" />
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 邮编：</td>
                <td class="tdRight">
                	<input maxlength="18" name="postcode"  class="txt" type="text"  value="{$member['postcode']}"/>
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 毕业学校：</td>
                <td class="tdRight">
                	<input maxlength="32"  name="school"  class="txt350" type="text"  value="{$member['school']}"  />
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 学历：</td>
                <td class="tdRight">
					<input  name="educationtype" type="radio"   {if 1==$member['educationtype'] }checked{/if}   value="1"/><label>博士后</label>
	                	<input  name="educationtype" type="radio"   {if 2==$member['educationtype'] }checked{/if}  value="2"/><label>博士</label>
	                	<input  name="educationtype" type="radio"   {if 3==$member['educationtype'] }checked{/if}  value="3"/><label>硕士</label>
	                	<input  name="educationtype" type="radio"   {if 4==$member['educationtype'] }checked{/if}   value="4"/><label>本科</label>
	                	<input  name="educationtype" type="radio"   {if 5==$member['educationtype'] }checked{/if}  value="5"/><label>专科</label>
	                	<input  name="educationtype" type="radio"   {if 6==$member['educationtype'] }checked{/if}  value="6"/><label>中学</label>
	                	<input  name="educationtype" type="radio"   {if 7==$member['educationtype'] }checked{/if}   value="7"/><label>其它</label>
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 工作单位：</td>
                <td class="tdRight">
                	<input maxlength="32"  name="company"  class="txt350" type="text"  value="{$member['company']}"  />
                </td>
              </tr> 
		   <tr>
                <td class="tdLeft"> 职业：</td>
                <td class="tdRight">
                	<input maxlength="18" name="jobskill"  class="txt" type="text"  value="{$member['jobskill']}"/>
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 职位：</td>
                <td class="tdRight">
                	<input maxlength="18" name="jobtitle"  class="txt" type="text"  value="{$member['jobtitle']}"/>
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 年收入：</td>
                <td class="tdRight">
                	<input maxlength="18" name="income"  class="txt" type="text"  value="{$member['income']}"/>元。
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 血型：</td>
                <td class="tdRight">
					<input  name="bloodtype" type="radio"   {if 1==$member['bloodtype'] }checked{/if}   value="1"/><label>A</label>
	                	<input  name="bloodtype" type="radio"   {if 2==$member['bloodtype'] }checked{/if}  value="2"/><label>B</label>
	                	<input  name="bloodtype" type="radio"   {if 3==$member['bloodtype'] }checked{/if}  value="3"/><label>AB</label>
	                	<input  name="bloodtype" type="radio"   {if 4==$member['bloodtype'] }checked{/if}   value="4"/><label>O</label>
	                	<input  name="bloodtype" type="radio"   {if 5==$member['bloodtype'] }checked{/if}  value="5"/><label>其它</label>
                </td>
              </tr>
		   <tr>
                <td class="tdLeft"> 性格测试：</td>
                <td class="tdRight">
					<input  name="charactertype" type="radio"   {if 1==$member['charactertype'] }checked{/if}   value="1"/><label>D</label>
	                	<input  name="charactertype" type="radio"   {if 2==$member['charactertype'] }checked{/if}  value="2"/><label>I</label>
	                	<input  name="charactertype" type="radio"   {if 3==$member['charactertype'] }checked{/if}  value="3"/><label>S</label>
	                	<input  name="charactertype" type="radio"   {if 4==$member['charactertype'] }checked{/if}   value="4"/><label>C</label>
	                	<input  name="charactertype" type="radio"   {if 5==$member['charactertype'] }checked{/if}  value="5"/><label>未知</label>
                </td>
              </tr>
              <tr>
                <td class="tdLeft">支付宝:</td>
                <td class="tdRight"><input maxlength="12" name="alipay" value="{$member['alipay']}" class="txt" type="text" ></td>
              </tr>
              <tr>
              <tr>
                <td class="tdLeft">QQ 号:</td>
                <td class="tdRight"><input maxlength="12" name="qq" value="{$member['qq']}" class="txt" type="text" ></td>
              </tr>
              <tr>
                <td class="tdLeft">MSN :</td>
                <td class="tdRight"><input maxlength="40" name="msn" value="{$member['msn']}" class="txt" type="text" ></td>
              </tr>
              <tr>
                <td class="tdLeft">阿里旺旺 :</td>
                <td class="tdRight"><input maxlength="40" name="aliwang" value="{$member['aliwang']}" class="txt" type="text" ></td>
              </tr>
              <tr>
                <td class="tdLeft">个人主页 :</td>
                <td class="tdRight"><input maxlength="40" name="homepage" value="{$member['homepage']}" class="txt350" type="text" ></td>
              </tr>
              <tr>
                <td class="tdLeft">兴趣爱好 :</td>
                <td class="tdRight"><input maxlength="40" name="hobby" value="{$member['hobby']}" class="txt350" type="text" ></td>
              </tr>
              <tr>
                <td class="tdLeft">个人情况简介:</td>
                <td class="tdRight"><textarea name="signature" id="signature"  rows="6" cols="50">{$member['signature']}</textarea></td>
              </tr>
              <tr>
                <td>&nbsp;</td>
                <td><input type="submit" name="submit" value="提 交" class="btn"></td>
              </tr>
            </tbody></table>
           
		</form>
	</div>
</div>
<script type="text/javascript">
function areaCallBack() {
  $('#conn-location-1').next().html('');
}

$(document).ready(function () {
  
  	$('#conn-location-1').connectSelectLocation({
		type:'normal',
		data:'js/location.js',
		select1:$('#conn-province'),
		select2:$('#conn-city'),
		select3:$('#conn-district'),
		current:[ $member['province'],$member['city'],$member['district'] ],
		fun1:function() { areaCallBack(); },
		fun2:function() { areaCallBack(); },
		fun3:function() { areaCallBack(); },
		callelement:$('#hdAddress'),
		space:[6,6,3]
    }); 
    
 addchild();
 
});

 function addchild(){
	var html='<tr><td class="tdLeft"><span style="color:red;">*</span>孩子姓名：</td><td class="tdRight"><input maxlength="12" name="childtruename[]"  class="txt" type="text" value="" />性别：<select  name="childgender[]"><option value="1">男</option><option value="2">女</option></select>生日：<input class="txt"  name="childbday[]" readonly  onclick="showcalendar();"  value=""  /></td></tr>';
	$(html).insertBefore('#morechild');
}
</script>
</body>

</html>
